function $(id){return document.getElementById(id)}
window.onload = function (){
     $("ipt1").addEventListener("click",function (){
          $("div1").className = "xian";
          $("div2").className = "yin";
          $("div3").className = "xian";
          $("div4").className = "yin";
     })

     $("ipt2").addEventListener("click",function (){
          $("div2").className = "xian";
          $("div1").className = "yin";
          $("div4").className = "xian";
          $("div3").className = "yin";
     })

}